/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package se.sll.engagemangsindex.ws;

import se.sll.engagemangsindex.dto.EngagementTypeImpl;
import se.sll.engagemangsindex.entity.Engagement;

/**
 *
 * @author khaleddaham
 */
class EngagementHelper {
    /**
     * 
     * @param engagementTypeImpl
     * @return 
     */
    public static Engagement toEngagement(EngagementTypeImpl engagementTypeImpl) {
        Engagement e = new Engagement();
        e.setBusinessObjectInstanceIdentifier(engagementTypeImpl.getBusinessObjectInstanceIdentifier());
        e.setCategorization(engagementTypeImpl.getCategorization());
        e.setClinicalProcessInterestId(engagementTypeImpl.getClinicalProcessInterestId());
        e.setOwner(engagementTypeImpl.getOwner());
        e.setRegisteredResidentIdentification(engagementTypeImpl.getRegisteredResidentIdentification());
        e.setServiceDomain(engagementTypeImpl.getServiceDomain());
        e.setSourceSystem(engagementTypeImpl.getSourceSystem());
        e.setLogicalAddress(engagementTypeImpl.getLogicalAddress());
        e.setMostRecentContent(engagementTypeImpl.getMostRecentContent());
        return e;
    }
}
